﻿using Common.CustomAtteibutes;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Parylene_CVD.Model.DModels
{
    // 设备信息表实体类
    [Table("Device")]
    [PrimaryKey("DeviceId", autoIncrement = true)]
    public class Device
    {
        public int DeviceId { get; set; }
        public string DeviceName { get; set; } = string.Empty;
        public string IP { get; set; } = string.Empty;
        public string Port { get; set; } = string.Empty;
        public DateTime CreateTime { get; set; }
        public DateTime UpdateTime { get; set; }

        public Device() { }

        public Device(string deviceName, string ip, string port, DateTime createTime, DateTime updateTime)
        {
            DeviceName = deviceName;
            IP = ip;
            Port = port;
            CreateTime = createTime;
            UpdateTime = updateTime;
        }

        public Device(int deviceId, string deviceName, string ip, string port, DateTime createTime, DateTime updateTime)
        {
            DeviceId = deviceId;
            DeviceName = deviceName;
            IP = ip;
            Port = port;
            CreateTime = createTime;
            UpdateTime = updateTime;
        }
    }
}
